package com.ls.controller;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import cn.tedu.crm.entity.Category;
import cn.tedu.crm.service.ICategoryService;
import cn.tedu.crm.util.JsonResult;

@Controller
@RequestMapping("/category")
public class CategoryController {
	@Resource(name = "categoryService")
	ICategoryService service;
	
	@RequestMapping("/option.do")
	@ResponseBody
	public JsonResult<List<Category>> findSource() {
		JsonResult<List<Category>> result = service.findCategory();
		return result;
	}

}
